package leetCode.firstWeek;

public class Code_9 {
    public boolean isPalindrome(int x) {
        String tmp = "" + x;
        for (int i = 0; i < tmp.length() / 2 + 1; i++) {
            if (tmp.charAt(i) != tmp.charAt(tmp.length() - 1 - i)) {
                return false;
            }
        }
        return true;
    }
}
